#include <stdio.h>
#include <unistd.h>
#include <fcntl.h>

int main()
{
  int fd;
  fd = open("./1.txt",O_RDWR | O_APPEND);
  if(fd < 0)
  {
    fprintf(stderr,"1.txt is open fail\n");
    return -1;
  }
  
  dup2(fd,STDIN_FILENO);
  
  char a[20];
  scanf("%s",a);
  close(fd);
  return 0;
}
